import 'package:base_plugin/base_plugin.dart';
import 'package:finance_app/src/common/app_colors.dart';
import 'package:finance_app/src/widgets/form/form_edit_status_inherited_widget.dart';
import 'package:flutter/material.dart';

class SubPriceForm extends StatelessWidget {
  final String title;
  final String amount;
  final bool isHighlight;

  const SubPriceForm({Key key, this.title, this.amount, this.isHighlight})
      : super(key: key);

  @override
  Widget build(BuildContext context) {
    final textStyle = isHighlight == true
        ? FormEditStatusInheritedWidget.ofStyle(context)
        : TextStyle(
            color: aceDarkGrayColor,
            fontSize: getSp(16),
            fontWeight: FontWeight.w700,
            height: 14 / 16,
          );
    return Row(
      mainAxisAlignment: MainAxisAlignment.spaceBetween,
      children: [
        Text(
          title,
          style: textStyle,
        ),
        Text(
          amount,
          style: textStyle
        ),
      ],
    );
  }
}
